/**
 * @file fr_device_rtc.h
 *
 * @author tangzheng
 */

#ifndef	__FR_DEVICE_RTC_H__
#define	__FR_DEVICE_RTC_H__

#ifdef __cplusplus
extern "C" {
#endif

/*********************
 *      INCLUDES
 *********************/


/*********************
 *      DEFINES
 *********************/




/**********************
 *      TYPEDEFS
 **********************/


typedef struct {
  signed char  h;
  signed char  m;
}time_zone_t;

/**********************
 *  STATIC PROTOTYPES
 **********************/


/**********************
 *  STATIC VARIABLES
 **********************/



/**********************
 *  VARIABLES
 **********************/


/**********************
 *      MACROS
 **********************/
#define UTC_BASE_YEAR			1970
#define MONTH_PER_YEAR			12
#define DAY_PER_YEAR			365
#define SEC_PER_DAY				86400
#define SEC_PER_HOUR			3600
#define SEC_PER_MIN				60

//default Time zone
#define DEFAULT_TIME_ZONE {8, 00}

/**********************
 *   EXTERN FUNCTIONS
 **********************/
extern void rtc_running(void);
extern void dev_rtc_time_init(void);
extern unsigned int get_sys_utc_time(void);

/**********************
 *   FUNCTIONS
 **********************/




#ifdef __cplusplus
} /*extern "C"*/
#endif

#endif